Thanks Shocker, but question remains. How do I do that?
Owen,
Provide your query for a more thorough recommendation. Shooting in the dark is not desired by volunteer contributors of this forum. Ideally the session for user id should be created upon login, not defined based off the result of a query later on.
You wrote:
| So what I want to do is once a user registers on the register page the page needs to redirect to a success page and have a message "Thanks User X for registering." |
You can also do this by simply echoing the post value on registration success page of the username 'name' that was 'named' whatever in the registration form. If registration form field for username is named username then echo on success page by entering this php
Thanks <?php echo $_POST['username']; ?> for registering.
Post values only survive the duration of one pageload. After that they are destroyed. So if you want to retain the data to display later on then you must create a session variable for the post value. Google the term how to create session variable or similar term and you will undoubtedly find countless resources that completely explain the process.
Keep in mind that by default Dreamweaver login server behavior automagically creates SESSION['MM_Username'] for the username of the logged in user. Simply echo the SESSION['MM_Username'] to display the username for the logged in user.
Look here: http://cookbooks.adobe.com/post_Display_user_s_name_and_other_details_after_login-16672.html
best,
Shocker 